<!DOCTYPE html>
<html class="no-js" lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>用户管理</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <link rel="shortcut icon" type="image/png" th:href="@{/assets/images/icon/favicon.ico}">
    <link rel="stylesheet" th:href="@{/assets/css/bootstrap.mincopy.css}">
    <link rel="stylesheet" th:href="@{/assets/css/font-awesome.min.css}">
    <link rel="stylesheet" th:href="@{/assets/css/themify-icons.css}">
    <link rel="stylesheet" th:href="@{/assets/css/metisMenu.css}">
    <link rel="stylesheet" th:href="@{/assets/css/owl.carousel.min.css}">
    <link rel="stylesheet" th:href="@{/assets/css/slicknav.min.css}">
    <!-- amchart css -->
    <link rel="stylesheet" th:href="@{/assets/css/export.css}" type="text/css" media="all"/>
    <!-- others css -->
    <link rel="stylesheet" th:href="@{/assets/css/typography.css}">
    <link rel="stylesheet" th:href="@{/assets/css/default-css.css}">
    <link rel="stylesheet" th:href="@{/assets/css/styles.css}">
    <link rel="stylesheet" th:href="@{/assets/css/responsive.css}">
    <!-- modernizr css -->
    <script th:src="@{assets/js/vendor/modernizr-2.8.3.min.js}"></script>

    <script type="text/javascript">

        function getKeyword() {

            var keyword = document.getElementById('searchKeyword');
            console.log(keyword);
            var form = document.getElementById('form');
            form.submit();

        }
    </script>
</head>
<body>

<div id="preloader">
    <div class="loader"></div>
</div>

<form id="form" th:action="@{/usercon/searchUser}" method="post">
    <div class="page-container">

        <div class="sidebar-menu">
            <div class="sidebar-header">
                <div class="logo"></div>
            </div>
            <div class="main-menu">
                <div class="menu-inner" style="width: 100%; height: 500px; overflow: hidden;">
                    <nav>
                        <ul class="metismenu" id="menu">
                            <li>
                                <a href="javascript:void(0)" aria-expanded="true"><i
                                        class="ti-dashboard"></i><span>上报记录管理</span></a>
                                <ul class="collapse">
                                    <li class="active"><a th:href="@{/recordcon/checkRecordAll}">全部记录</a></li>
                                </ul>
                                <ul class="collapse">
                                    <li class="active"><a th:href="@{/recordcon/recordAnalysis}">记录分析</a></li>
                                </ul>
                                <ul class="collapse">
                                    <li class="active"><a th:href="@{/usercon/notDoUser}">未打卡用户</a></li>
                                </ul>
                            </li>

                            <li class="active">
                                <a href="javascript:void(0)" aria-expanded="true"><i
                                        class="fa fa-table"></i><span>用户管理</span></a>
                                <ul class="collapse">
                                    <li><a th:href="@{/usercon/User}">用户信息</a></li>
                                </ul>
                            </li>
                            <li>
                                <a href="javascript:void(0)" aria-expanded="true"><i
                                        class="fa fa-table"></i><span>管理员信息</span></a>
                                <ul class="collapse">
                                    <li><a th:href="@{/usercon/AdUser}">管理员账号</a></li>
                                </ul>
                            </li>
                            <li><a th:href="@{/outLogin}"><i class="ti-map-alt"></i> <span>退出登录</span></a></li>
                        </ul>
                    </nav>
                </div>
            </div>
        </div>
        <!-- sidebar menu area end -->
        <!-- main content area start -->
        <div class="main-content">
            <div class="header-area">
                <div class="row align-items-center">
                    <!-- nav and search button -->
                    <div class="col-md-6 col-sm-8 clearfix">
                        <div class="nav-btn pull-left">
                            <span></span>
                            <span></span>
                            <span></span>
                        </div>
                        <div class="search-box pull-left">
                            <input type="text" id="searchKeyword" name="searchKeyword" required="required"
                                   runat="server"
                                   th:placeholder="输入关键字搜索">
                            <div class="pagination_area pull-right ">
                                <ul>
                                    <li><a onclick="getKeyword()">确定</a></li>
                                </ul>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
            <div class="main-content-inner">
                <div class="table-responsive">
                    <div class="table-responsive">
                        <table class="dbkit-table">
                            <tbody>
                            <tr align="center">
                                <td><h4><a th:href="@{/usercon/UserOrderById}" href="#">id</a></h4></td>
                                <td><h4><a th:href="@{/usercon/UserOrderByUserId}" href="#">账号</a></h4></td>
                                <td><h4><a th:href="@{/usercon/UserOrderByName}" href="#">姓名</a></h4></td>
                                <td><h4><a th:href="@{/usercon/UserOrderByAddress}" href="#">地址</a></h4></td>
                                <td><h4>今日打卡</h4></td>
                                <td><h4>连续打卡数</h4></td>
                                <td><h4>登录权限</h4></td>
                                <td>
                                    <div class="pagination_area pull-right ">
                                        <ul>
                                            <li><a th:href="@{/UserExcel}" href="#">导出</a>
                                            </li>
                                        </ul>
                                    </div>
                                </td>
                            </tr>
                            <tr th:each="users:${userMessages}" align="center">
                                <td th:id="'id'+${users.getId()}" th:text="${users.getId()}"></td>
                                <td th:text="${users.getUserid()}"></td>
                                <td th:text="${users.getUsername()}"></td>
                                <td th:text="${users.getAddress()}"></td>
                                <td th:switch="${users.getIsdo()}">
                                    <span th:case="1">已打卡</span>
                                    <span th:case="0">未打卡</span>
                                </td>
                                <td th:text="${users.getDodata()}"></td>
                                <td th:switch="${users.getIslock()}">
                                    <span th:case="1">无</span>
                                    <span th:case="0">有</span>
                                </td>
                                <td>
                                    <div class="pagination_area pull-right ">
                                        <ul>
                                            <li><a th:id="${users.getId()}"
                                                   th:href="@{/recordcon/checkRecord(id=${users.getId()})}" href="#">记录</a>
                                            </li>
                                            <li th:if="${users.getIslock()==0}"><a th:id="${users.getId()}"
                                                   th:href="@{/usercon/updateLock(id=${users.getId()},isLock=${users.getIslock()})}"
                                                   href="#">锁定</a>
                                            </li>
                                            <li th:if="${users.getIslock()==1}">
                                                <a th:id="${users.getId()}" th:href="@{/usercon/updateLock(id=${users.getId()},isLock=${users.getIslock()})}" href="#">解锁</a>
                                            </li>
                                        </ul>
                                    </div>
                                </td>
                            </tr>
                            </tbody>
                        </table>
                    </div>
                </div>

            </div>

        </div>
    </div>
    </div>
</form>
<script th:src="@{/assets/js/vendor/jquery-2.2.4.min.js}"></script>
<script th:src="@{/assets/js/popper.min.js}"></script>
<script th:src="@{/assets/js/bootstrap.min.js}"></script>
<script th:src="@{/assets/js/owl.carousel.min.js}"></script>
<script th:src="@{/assets/js/metisMenu.min.js}"></script>
<script th:src="@{/assets/js/jquery.slimscroll.min.js}"></script>
<script th:src="@{/assets/js/jquery.slicknav.min.js}"></script>

<!-- start chart js -->
<script th:src="@{/assets/js/Chart.min.js}"></script>
<!-- start highcharts js -->
<script th:src="@{/assets/js/highcharts.js}"></script>
<!-- start zingchart js -->
<script th:src="@{/assets/js/zingchart.min.js}"></script>
<script>
    zingchart.MODULESDIR = "assets/js/modules/";
    ZC.LICENSE = ["569d52cefae586f634c54f86dc99e6a9", "ee6b7db5b51705a13dc2339db3edaf6d"];
</script>
<!-- all line chart activation -->
<script th:src="@{https://www.amcharts.com/lib/3/amcharts.js}"></script>
<script th:src="@{https://www.amcharts.com/lib/3/serial.js}"></script>
<script th:src="@{/assets/css/export.min.js}"></script>
<script th:src="@{https://www.amcharts.com/lib/3/themes/light.js}"></script>
<script th:src="@{/assets/js/bar-chart-main.js}"></script>
<script th:src="@{/assets/js/line-chart-main.js}"></script>
<!-- all pie chart -->
<script th:src="@{/assets/js/pie-chart.js}"></script>
<!-- others plugins -->
<script th:src="@{/assets/js/plugins.js}"></script>
<script th:src="@{/assets/js/scripts.js}"></script>

<script th:src="@{/assets/search.js}"></script>
<script th:src="@{/assets/order.js}"></script>
<script th:src="@{/assets/good.js}"></script>

</body>
</html>